1. Field of the Invention
The invention relates to an authentication method and related device used in a digital versatile disk (DVD) system, and more particularly, to a method and related device using several independent mapping relationships to simplify the encoding process during authentication.
2. Description of the Prior Art
Since the technology of digital versatile disks (DVDs) is developed, DVD shave become one of the most important storage media of information industry. The capacity and density of DVDs are far more than those of current compact disks (CDs). They are capable of storing a large capacity of video and multi-media data, enriching lives of people, and furthermore, recording large quantities of information and knowledge for the basis of the development of technology.
The data stored in DVDs can be read by DVD-Rom (read only memory) drives. To maintain the legitimacy of reading the DVD title, an authentication mechanism has been set in constituting the specification of the DVD system. Please refer to FIG. 1. FIG. 1 is a function block diagram of a disk-play platform 10 cooperating with a DVD drive 14 for playing a DVD. The disk-play platform 10 of a DVD system could be a personal computer (PC). a master controller 12 of the disk-play platform 10 could be a DVD data decoding circuit in hardware, or a DVD playing software performed by the disk-play platform 10. The disk-play platform 10 controls the DVD drive 14 to read the data of the DVD. For avoiding the illegal use of the DVD, the master controller 12 will confirm the legality of the DVD drive 14. The authentication mechanism is as follows. The master controller 12 first sends an inquiring code 16 to the DVD drive 14. Then the DVD drive 14 encodes the inquiring code 16 into an authentication code 18 according to a regulative encoding method and responds to the master controller 12 with the authentication code 18. The master controller 12 checks the authentication code 18 given by the DVD drive 14 to determine whether the DVD drive 14 is legal. When the DVD drive 14 passes in authentication, it sends another inquiring code to authenticate the master controller 12. Then the master controller 12 performs a procedure shown in FIG. 2 to generate a corresponding authentication code according to the inquiring code sent by the DVD drive 14 and sends back to the DVD drive 14 so as to authenticate that the master controller 12 is also legal . After the above-mentioned mutual authentication process, the DVD drive 14 further reads the authenticated data of the DVD for authenticating the master controller 12 (the DVD drive 14 sends another inquiring code and checks the corresponding authentication code generated and sent back by the master controller 12). Only DVD systems that pass the above-mentioned authentication are capable of reading the data of DVDs correctly.
Please refer to FIG. 2. FIG. 2 is a schematic diagram of the procedure of the DVD drive 14 generating the authentication code 18 corresponding to the inquiring code 16. According to the specification of DVD system, the inquiring code 16 generated by the master controller 12 is encoded by a pre-procedure 22. Then the encoded result from the pre-procedure 22 is further mapped to another code according to a pre-table 24. After another encoding by a mid-procedure 26, the encoded result is again mapped to another code according to a post-table 28. Finally, the authentication code 18 is generated by a post-procedure 30. The pre-procedure 22, the mid-procedure 26, and the post-procedure 30 are defined in the specification of the DVD system, and the detailed information is well known in the industry field. For brevity, further details are omitted here. Please refer to FIG. 3 and FIG. 4 for showing the mapping of the pre-table 24 and the post-table 28.
FIG. 3 and FIG. 4 respectively show the table look-up relationship set up by the pre-table 24 and the post-table 28. The inquiring code 16 is eight bits when inputted into the pre-table 24 and the post-table 30. The mapping result from the pre-table 24 and the post-table 30 are also 8 bits. For convenience, all numbers shown in FIG. 3 and FIG. 4 are hexadecimal (In other words, the numbers of 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E, F shown in FIG. 3 and FIG. 4 respectively represent the decimal numbers of 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15). The most significant bit (MSB) is used as the 7th bit, and the least significant bit (LSB) is used as 0th bit. The row 24A shown in FIG. 3 includes sixteen kinds of combinations of the 7th bit to the 4th bit of the inquiring code inputted into the table 24, and the column 24B shown in FIG. 3 includes sixteen kinds of combinations of the 3rd bit to the 0th bit of the inquiring code inputted into the table 24. A numeral composed of two hexadecimal numbers at a junction of the row 24B and the column 24A represent the output according to the pre-table 24. For example, if an inquiring code inputted into the pre-table 24 is 00 (hexadecimal), then the inquiring code is mapped to 4C (hexadecimal) according to the pre-table 24 shown in FIG. 3. As well, if the inputted inquiring code is 9A, then the pre-table 24 outputs 5A. Based on the same principle, the row 28A shown in FIG. 4 includes sixteen kinds of combinations of the 7th bit to the 4th bit of the input of the post-table 28, and the column 28B includes sixteen kinds of combinations of the 3rd bit to the 0th bit of the input of the post-table 28. An output, which is composed of two hexadecimal numbers, of the post-table 28 is at a junction of the row 28A and the column 28B. For example, if an input inquiring code is 31 (hexadecimal), then the inquiring code is mapped to 64 (hexadecimal) as an output according to the post-table 28 shown in FIG. 4. As well, if the inputted inquiring code is 8E (hexadecimal), then the inquiring code is mapped to 1F (hexadecimal) according to the post-table 28.
In the prior DVD drives, the pre-table 24 and the post-table 28 shown in FIG. 3 and FIG. 4 are directly implemented by a logic circuit. In other words, a designed logic circuit composed of many logic gates is formed to implement table look-up relationships set by the above-mentioned two tables. An inquiring code in the form of digital signal is inputted into the logic circuit. After the operation of the logic circuit, the inquiring code is mapped to an output in the form of a digital signal according to the pre-table (or post-table). However, the larger and more complex the table, the more logic gates are required. As shown in FIG. 3 and FIG. 4, the pre-table 24 and the post-table 28 defined in the specification of the DVD system are used to deal with all 256 kinds of combinations of an eight-bit input mapped to an eight-bit output. In the prior art, the pre-table 24 and the post-table 28 shown in FIG. 3 and FIG. 4 are directly implemented by a logic circuit, and therefore, the logic circuit is completed and the gate count is great. For containing a large number of logic gates and a complex layout, the logic circuit used to implement the pre-table and the post-table occupies some layout area and also consumes great power, which results in bad effects on the integration and the energy efficiency of DVD drive circuits. In addition, every logic gate brings a specified gate delay, so the more logic circuits used, the lower the operating efficiency of the logic circuit is. Furthermore, for ensuring normal operation of the logic circuit used for implementing the pre-table and the post-table, the logic circuit must be tested during manufacturing processes. The prior art directly calculates 256 kinds of combinations included in the pre-table and the post-table. Therefore, all 256 kinds of combinations must be tested during manufacturing processes, which wastes time and increases the production cost.